#include <vector>
#include <stdio.h>
#include <iostream>
#include "Person.h"
#include <opencv/cv.h>
#include "Blob/BlobResult.h"

/**
* @class PeopleDetector
*
* @brief Methods for finding people in images
*
*
* Finds people in OpenCV matrices, using blobbing methods.
*
* @author Elisabeth Lindquist, elisabeth.lindquist@gmail.com
*
*/
using namespace std;
using namespace cv;

class PeopleDetector{

    public:
        vector<Person> findPeople(Mat &mat, Mat &mask, Mat &depth);

    private:
        bool isPerson(CBlob *blob);
        Person createPerson(CBlob *blob, int id, Mat &depth);
        float calcDistance(CBlob *blob, Mat& depth);
        float calcSpeed(CBlob *blob);
        float calcGathered(CBlob *blob);

        int findPose(CBlob *blob);



};
